package com.sinodata.bsm.center.bean;

import com.sinodata.bsm.center.cache.EventTypeCache;
import com.sinodata.bsm.center.util.spring.SpringContextHolder;
import com.sinodata.bsm.common.vo.EventType;

/**
 * <p>
 * Description: 
 * </p>
 *
 * @author liulibo
 * @version 1.0

 * <p>
 * History: 
 *
 * Date                     Author         Version     Description
 * ---------------------------------------------------------------------------------
 * 2012-6-29 PM 2:56:42     liulibo        1.0         To create
 * </p>
 *
 * @since 
 * @see     
 */
public class EventTypeBean {

    /**
     * 事件类别POJO缓存
     */
    private static EventTypeCache eventTypeCache = SpringContextHolder.getBean(EventTypeCache.class);

    private EventType eventType;

    private EventTypeBean() {

    }

    private EventTypeBean(EventType eventType) {
        this.eventType = eventType;
    }

    public static EventTypeBean get(Long id) {
        return new EventTypeBean(eventTypeCache.get(id));
    }

    public EventType eventType() {
        return this.eventType;
    }

}
